package com.nondo.dean.dealer.mapper;

import com.nondo.dean.dealer.model.result.CustomerViewResult;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author xiaofan
 * @Description:
 * @throws
 * @date 2018-05-1814:25
 * @Version
 */
@Component
public interface CustomerViewExtendsMapper {

    /**
     * 产品浏览次数统计
     * @param id
     * @return
     */
    @Select("select count(go_value) as count,go_value,type from customer_view where customer_id=#{id,jdbcType=INTEGER} and type=1 GROUP BY go_value")
    List<CustomerViewResult> selectByExample(@Param("id") Integer id);
}
